<?php include $this->header();?>
<?php if(false) {?>
<link rel="stylesheet" rev="stylesheet" href="../../../images/admincp/style.css" type="text/css" media="all" />
<?php }?>
<form method="post" enctype="application/x-www-form-urlencoded" target="_self" onsubmit="return Validator.Validate(this)">
<div class="bd p1 mt">
    <ul class="tabs">
      <li><a href="#">基本选项</a></li>
      <li><a href="#">SEO</a></li>
      <li><a href="#">显示设置</a></li>
      <li><a href="#">模板设置</a></li>
    </ul>
    <div class="panes">
      <table width="100%" border="0" cellspacing="0" cellpadding="0" class="rank">
        <tr>
            <td width="140" align="right" valign="middle">分类名称</td>
            <td><input name="cat_name" type="text" class="text-box" id="cat_name" onblur="Validator.check(this)" value="<?=$catArr['cat_name']?>" size="45" dataType="Require" msg="请填写栏目名称" /> <b class="red">*</b></td>
        </tr>
        <tr>
            <td align="right" valign="middle">上级分类</td>
            <td>
              <select name="cat_parent_id" id="cat_parent_id">
                  <option value="0">顶级分类</option>
                  <?php foreach ($_cats as $_cat) {?>
                  <option value="<?=$_cat['cat_id']?>" <?php if($catArr['cat_parent_id'] == $_cat['cat_id']){?>selected="selected"<?php } if( in_array($_cat['cat_id'], $_cats[$catArr['cat_id']]['chile'])){?> disabled="disabled"<?php }?> ><?=$_cat['icon']?><?=$_cat['cat_name']?></option>
                  <?php }?>
                  
              </select>
              <span class=" note">（不选择则为顶级栏目）</span></td>
        </tr>
        <tr>
            <td width="140" align="right" valign="middle">应用</td>
            <td>
                <select name="cat_app" id="cat_app" disabled="disabled">
                    <?php foreach($useCatApps as $catApp){?>
                    <option value="<?=$catApp['app_id']?>" <?php if($catArr['cat_app'] == $catApp['app_id']){?> selected="selected"<?php }?> ><?=$catApp['app_name']?></option>
                    <?php }?>
                </select>
            </td>
        </tr>
        <tr>
            <td width="140" align="right" valign="middle">栏目说明</td>
            <td>
                <textarea name="cat_note" id="cat_note" cols="42" rows="5"><?=$catArr['cat_note']?></textarea>
            </td>
        </tr>
        <tr>
            <td align="right" valign="middle">URL</td>
            <td><input name="cat_url" type="text" class="text-box" id="cat_url" value="<?=$catArr['cat_url']?>" size="45" />
                <span class="note">（如果设置，则点击后将跳转到该url）</span></td>
        </tr>
        <tr>
            <td width="140" align="right" valign="middle">是否启用</td>
            <td>
                <input name="cat_enabled" value="1" <?php if($catArr['cat_enabled']){?>checked="checked" <?php }?> type="radio" />
                是
        <input name="cat_enabled" value="0" <?php if(!$catArr['cat_enabled']){?>checked="checked" <?php }?> type="radio" />
                否
                
                <span class="note">（选择&quot;是&quot;，则该分类下得到商品在前台显示，选择&quot;否&quot;，则不显示）</span></td>
        </tr>
        <tr>
            <td align="right" valign="middle" class="nobd">&nbsp;</td>
            <td class="nobd"><input class="btn" type="submit" value="修改" />
                <input name="重置" type="reset" class="btn" value="重置" /></td>
        </tr>
      </table>
      <table width="100%" border="0" cellspacing="0" cellpadding="0" class="rank">
        <tr>
            <td width="140" align="right" valign="middle">URL优化</td>
            <td><input name="cat_slug" type="text" class="text-box" id="cat_slug" value="<?=urldecode($catArr['cat_slug'])?>" size="45" /></td>
        </tr>
        <tr>
            <td width="140" align="right" valign="middle">页面标题</td>
            <td><input name="cat_title" type="text" class="text-box" id="cat_title" value="<?=urldecode($catArr['cat_title'])?>" size="45" /></td>
        </tr>
        <tr>
            <td width="140" align="right" valign="middle">页面关键词</td>
            <td><input name="cat_keyword" type="text" class="text-box" id="cat_keyword" value="<?=$catArr['cat_keyword']?>" size="45" /></td>
        </tr>
        <tr>
            <td width="140" align="right" valign="middle">页面描述</td>
            <td>
                <textarea name="cat_description" id="cat_description" cols="42" rows="5"><?=$catArr['cat_description']?></textarea>
            </td>
        </tr>
        <tr>
            <td align="right" valign="middle" class="nobd">&nbsp;</td>
            <td class="nobd"><input class="btn" type="submit" value="修改" />
                <input name="重置" type="reset" class="btn" value="重置" /></td>
        </tr>
      </table>
      <table width="100%" border="0" cellspacing="0" cellpadding="0" class="rank">
        <tr>
            <td align="right" valign="middle">是否在导航栏显示</td>
            <td><input name="cat_nav_show" value="1" type="radio" <?php if($catArr['cat_nav_show']){?>checked="checked" <?php }?> />
                是
                <input name="cat_nav_show" value="0" type="radio" <?php if(!$catArr['cat_nav_show']){?>checked="checked" <?php }?> />否 </td>
        </tr>
        <tr>
            <td align="right" valign="middle">导航栏显示排序</td>
            <td><input name="cat_order" type="text" class="text-box" id="cat_order" value="<?=$catArr['cat_order']?>" size="5" />
                <span class="note">（数字越小，排序越靠前）</span></td>
        </tr>
        <tr>
            <td width="140" align="right" valign="middle">是否在首页显示</td>
            <td>
                <input name="cat_homepage_show" value="1" <?php if($catArr['cat_homepage_show']){?>checked="checked" <?php }?> type="radio" />是
                <input name="cat_homepage_show" value="0" <?php if(!$catArr['cat_homepage_show']){?>checked="checked" <?php }?> type="radio" />否
            </td>
        </tr>
        <tr>
            <td width="140" align="right" valign="middle">首页显示排序</td>
            <td>
                <input name="cat_homepage_order" type="text" value="<?=$catArr['cat_homepage_order']?>" />
            </td>
        </tr>
        <tr>
            <td width="140" align="right" valign="middle">网站首页显示模式</td>
            <td>
                <select name="cat_homepage_mode">
                    <option value="tab" <?php if(empty($catArr['cat_homepage_mode'])){ ?> selected="selected"<?php } ?>>请选择显示模式</option>
                    <option value="tab" <?php if('tab' == $catArr['cat_homepage_mode']){ ?> selected="selected"<?php } ?>>标签切换显示子分类文章</option>
                    <option value="all" <?php if('all' == $catArr['cat_homepage_mode']){ ?> selected="selected"<?php } ?>>显示分类及子分类全部文章</option>
                </select>
            </td>
        </tr>
        <tr>
            <td width="140" align="right" valign="middle">是否在栏目首页显示</td>
            <td>
                <input name="cat_page_show" value="1" type="radio" <?php if($catArr['cat_page_show']){?>checked="checked" <?php }?> />是
                <input name="cat_page_show" value="0" type="radio" <?php if(!$catArr['cat_page_show']){?>checked="checked" <?php }?> />否
            </td>
        </tr>
        <tr>
            <td width="140" align="right" valign="middle">栏目首页显示排序</td>
            <td>
                <input name="cat_page_order" value="<?=$catArr['cat_page_order']?>" type="text" />
            </td>
        </tr>
        <tr>
            <td width="140" align="right" valign="middle">栏目首页显示模式</td>
            <td>
                <select name="cat_page_mode">
                    <option value="tab" <?php if(empty($catArr['cat_page_mode'])){ ?> selected="selected"<?php } ?>>请选择显示模式</option>
                    <option value="tab" <?php if('tab' == $catArr['cat_page_mode']){ ?> selected="selected"<?php } ?>>标签切换显示子分类文章</option>
                    <option value="list" <?php if('list' == $catArr['cat_page_mode']){ ?> selected="selected"<?php } ?>>按子栏目显示列表</option>
                    <option value="all" <?php if('all' == $catArr['cat_page_mode']){ ?> selected="selected"<?php } ?>>显示分类及子分类全部文章</option>
                </select>
            </td>
        </tr>
        <tr>
            <td align="right" valign="middle" class="nobd">&nbsp;</td>
            <td class="nobd"><input class="btn" type="submit" value="修改" />
                <input name="重置" type="reset" class="btn" value="重置" /></td>
        </tr>
      </table>
      <table width="100%" border="0" cellspacing="0" cellpadding="0" class="rank">
        <tr>
            <td width="140" align="right" valign="middle">栏目首页模板</td>
            <td>
                <select name="cat_tpl">
                    <option value="info/show.cat" <?php if('info/show.cat' == $catArr['cat_tpl']){ ?>selected="selected"<?php } ?>>默认(info/show.cat.html)</option>
                </select>
                <span class="note">有子分类时页面使用的模板</span>
            </td>
        </tr>
        <tr>
            <td width="140" align="right" valign="middle">栏目列表页模板</td>
            <td>
                <select name="cat_list_tpl">
                    <option value="info/show.list" <?php if('info/show.list' == $catArr['cat_list_tpl']){ ?>selected="selected"<?php } ?>>默认(info/show.list.html)</option>
                </select>
                <span class="note">栏目文章列表页面使用的模板</span>
            </td>
        </tr>
        <tr>
            <td width="140" align="right" valign="middle">详细页模板</td>
            <td>
                <select name="cat_item_tpl">
                    <option value="info/show.item" <?php if('info/show.item' == $catArr['cat_item_tpl']){ ?>selected="selected"<?php } ?>>默认(info/show.item.html)</option>
                </select>
                <span class="note">详细内容页面使用的模板</span>
            </td>
        </tr>
        <tr>
            <td align="right" valign="middle" class="nobd">&nbsp;</td>
            <td class="nobd"><input class="btn" type="submit" value="修改" />
                <input name="重置" type="reset" class="btn" value="重置" /></td>
        </tr>
      </table>
    </div>
</div>
</form>
<?php include $this->footer();?>